import { get, post } from '@/axios';

export function postLogin (params) {
  return get('/house/login', params);
}

export function getHouseList (data) {
  return post('/house/list', data);
}

export function getSubwayLines (data) {
  return post(
    'https://apis.gzmtr.com/app-map/metroweb/linestation?auto_type=key&acccesskey=247919A174804353AE72BAB00981C6E8',
    data
  );
}

export function multipleImageUploads (files) {
  return post(
    '/minio/uploads',
    files,
    {
      headers: {
        'Content-Type': 'multipart/form-data',
      },
    }
  );
}
export function PostUploadFile (file) {
  return post(
    '/minio/upload',
    { file },
    {
      headers: {
        'Content-Type': 'multipart/form-data',
      },
    }
  );
}

export function addRoom (data) {
  return post('/house/add', data);
}

export function requestHouseAreaEnu (params) {
  return get('/house/houseArea', params);
}

export function requesHousesNumberEnu (params) {
  return get('/house/houseNumType', params);
}

export function requesSubwaylineArray (params) {
  return get('/house/subway', params);
}

export function requesRoomDetails (params) {
  return get('/house/get', params);
}

export function houseDelete (params) {
  return get('/house/delete', params);
}
export function houseModify (params) {
  return post('/house/edit', params);
}
